package com.vsen.lpr.controller;

import com.vsen.lpr.common.base.BaseController;
import com.vsen.lpr.common.model.Response;
import com.vsen.lpr.pojo.dto.BalanceDto;
import com.vsen.lpr.pojo.dto.BannerDto;
import com.vsen.lpr.pojo.dto.InsertBannerDto;
import com.vsen.lpr.pojo.vo.BalanceVo;
import com.vsen.lpr.service.BalanceService;
import com.vsen.lpr.service.BannerService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.validation.BindingResult;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

@Controller
@RequestMapping("/balance")
@Slf4j
public class BalanceController extends BaseController {

    @Autowired
    private BalanceService balanceService;

    /**
     * 查询余额
     *
     * @param dto
     * @return
     */
    @PostMapping("/balanceInfo")
    @ResponseBody
    Response<BalanceVo> balanceInfo(@RequestBody BalanceDto dto) {
        return balanceService.balanceInfo(dto);
    }

}
